/* 主要布局容器 */
.main-container {
    max-width: 1500px;
    margin: 2rem auto;
    padding: 0 1rem;
    display: grid;
    grid-template-columns: 350px 1fr;
    gap: 2rem;
    min-height: calc(100vh - 500px);
}

/* 确保所有页面容器样式一致 */
.container {
    max-width: 1200px;
    margin: 0 auto;
    padding: 0 20px;
}

/* 侧边栏样式 */
.sidebar {
    height: 100%;
    display: flex;
    flex-direction: column;
}

/* 用户信息样式 */
.user-profile {
    background: linear-gradient(135deg, 
        rgba(255, 140, 100, 0.9),
        rgba(255, 180, 160, 0.9)
    );
    border-radius: 8px;
    padding: 1.5rem;
    text-align: center;
    box-shadow: 0 4px 15px rgba(255, 140, 100, 0.15);
    margin-bottom: 2rem;
    flex-shrink: 0;
    color: var(--text-light);
    border: 1px solid rgba(255, 200, 180, 0.3);
    backdrop-filter: blur(5px);
}

.avatar {
    width: 120px;
    height: 120px;
    margin: 0 auto 1rem;
    border-radius: 50%;
    overflow: hidden;
    border: 3px solid rgba(255, 255, 255, 0.4);
    box-shadow: 0 2px 10px rgba(255, 140, 100, 0.2);
}

.avatar img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    border-radius: 50%;
    transition: transform 0.3s ease;
}

.avatar:hover img {
    transform: scale(1.05);
}

.username {
    font-size: 1.2rem;
    margin-bottom: 0.5rem;
    color: var(--text-light);
    font-weight: 500;
    text-shadow: 1px 1px 10px rgba(0, 0, 0, 0.1);
}

.user-description {
    color: rgba(255, 255, 255, 0.95);
    font-size: 0.9rem;
    text-shadow: 1px 1px 8px rgba(0, 0, 0, 0.1);
    line-height: 1.4;
}

/* 搜索框样式 */
.search-box {
    background: var(--surface-color);
    border-radius: 8px;
    padding: 1rem;
    box-shadow: 0 1px 3px var(--shadow-color);
    margin-bottom: 2rem;
    display: flex;
    gap: 0.5rem;
    flex-shrink: 0;
}

.search-box input {
    flex: 1;
    padding: 0.5rem;
    border: 1px solid var(--border-color);
    border-radius: 4px;
    font-size: 0.9rem;
}

.search-box button {
    background: var(--primary-color);
    color: var(--text-light);
    border: none;
    padding: 0.5rem 1rem;
    border-radius: 4px;
    cursor: pointer;
    transition: background 0.3s;
}

.search-box button:hover {
    background: var(--primary-dark);
}

/* 推荐文章样式 */
.recommended-posts {
    background: var(--primary-light);
    border-radius: 8px;
    padding: 1.5rem;
    box-shadow: 0 2px 5px var(--shadow-color);
    flex: 1;
    overflow-y: auto;
    max-height: 400px;
}

.recommended-posts h4 {
    margin-bottom: 1rem;
    font-size: 1.1rem;
    position: sticky;
    top: 0;
    background: #fff;
    padding-bottom: 0.5rem;
    z-index: 1;
}

.recommended-posts ul {
    list-style: none;
    padding: 0;
    margin: 0;
}

.recommended-posts li {
    margin-bottom: 1rem;
    padding: 0.5rem;
    border-radius: 4px;
    transition: all 0.3s ease;
}

.recommended-posts li:last-child {
    margin-bottom: 0;
}

.recommended-posts li:hover {
    background-color: var(--surface-color);
    box-shadow: 0 2px 4px var(--shadow-color);
}

.recommended-posts a {
    display: flex;
    gap: 1rem;
    text-decoration: none;
    color: inherit;
    align-items: center;
}

.recommended-posts img {
    width: 50px;
    height: 50px;
    object-fit: cover;
    border-radius: 4px;
}

.post-info h5 {
    margin: 0 0 0.3rem;
    font-size: 0.9rem;
}

.post-info span {
    color: var(--text-secondary);
    font-size: 0.8rem;
}

/* 主要内容区域样式 */
.main-content {
    background: var(--surface-color);
    border-radius: 8px;
    padding: 2rem;
    box-shadow: 0 2px 5px var(--shadow-color);
}

.main-content h2 {
    margin-bottom: 2rem;
    font-size: 1.5rem;
}

/* 文章网格布局 */
.post-grid {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 2rem;
}

/* 文章卡片样式 */
.post-card {
    background: var(--surface-color);
    border-radius: 8px;
    overflow: hidden;
    box-shadow: 0 1px 3px var(--shadow-color);
    transition: all 0.3s ease;
}

.post-card:last-child {
    margin-bottom: 0;
}

.post-card:hover {
    transform: translateY(-5px);
    box-shadow: 0 4px 12px var(--shadow-color);
}

.post-card img {
    width: 100%;
    height: 200px;
    object-fit: cover;
}

.post-content {
    padding: 1.5rem;
}

.post-content h3 {
    margin-bottom: 0.5rem;
}

.post-date {
    color: #666;
    font-size: 0.9rem;
}

/* 响应式设计 */
@media (max-width: 768px) {
    .main-container {
        grid-template-columns: 1fr;
    }

    .sidebar {
        margin-bottom: 2rem;
    }

    .post-grid {
        grid-template-columns: 1fr;
    }
}

/* 平板电脑布局 */
@media (min-width: 769px) and (max-width: 1200px) {
    .post-grid {
        grid-template-columns: repeat(2, 1fr);
    }
}

/* 标签云样式 */
.tags-container {
    background: var(--surface-color);
    border-radius: 8px;
    padding: 1.5rem;
    box-shadow: 0 1px 3px var(--shadow-color);
    margin-top: 2rem;
}

.tags-container h4 {
    margin-bottom: 1rem;
    font-size: 1.1rem;
    color: var(--text-primary);
}

.tags-grid {
    display: grid;
    grid-template-columns: repeat(2, 1fr);
    gap: 1rem;
}

.tag-card {
    padding: 0.8rem;
    border-radius: 8px;
    display: flex;
    justify-content: space-between;
    align-items: center;
    transition: all 0.3s ease;
    cursor: pointer;
}

.tag-card:hover {
    transform: translateY(-2px);
    box-shadow: 0 2px 4px var(--shadow-color);
}

.tag-name {
    font-size: 0.9rem;
    color: var(--text-primary);
    font-weight: 500;
}

.tag-count {
    background: rgba(255, 255, 255, 0.5);
    padding: 0.2rem 0.6rem;
    border-radius: 12px;
    font-size: 0.8rem;
    color: var(--text-secondary);
} 